<!DOCTYPE html>
<html>
<head>
    <meta http-equiv="content-type" content="text/html;charset=utf-8">
    <meta name="viewport" content="width=device-width,minimum-scale=1,maximum-scale=1,user-scalable=no">
    <title>大数据融合与挖掘分析平台</title>
    <link rel="stylesheet" type="text/css" href="/layui/css/layui.css">
    <link href="/css/common.css" type="text/css" rel="stylesheet">
    <link rel="stylesheet" type="text/css" href="/css/nav.css">
    <link rel="stylesheet" type="text/css" href="/css/iconfont.css">
    <link href="/css/bootstrap.min.css" title="" rel="stylesheet" />
    <link title="" href="/css/body.css" rel="stylesheet" type="text/css" />
    <link title="" href="/css/style.css" rel="stylesheet" type="text/css" />
    <link title="blue" href="/css/dermadefault.css" rel="stylesheet" type="text/css" />
    <link title="green" href="/css/dermagreen.css" rel="stylesheet" type="text/css" disabled="disabled" />
    <link title="orange" href="/css/dermaorange.css" rel="stylesheet" type="text/css" disabled="disabled" />
    <link href="/css/templatecss.css" rel="stylesheet" title="" type="text/css" />
    <script src="/js/jquery-1.11.1.min.js" type="text/javascript"></script>
    <script src="/layui/layui.js"></script>
    <script src="/js/alert.js"></script>
    <script src="/js/echarts.min.js"></script>
    <script src="/js/jquery.cookie.js" type="text/javascript"></script>
    <script src="/js/bootstrap.min.js" type="text/javascript"></script>
    <script src="/js/style.js"></script>
    <!--angular ui--->
    <link rel="stylesheet" title="" type="text/css" href="/css/ui-layout.css" />
    <script src="/js/angular.min.js"></script>
    <script src="/js/ui-layout.js"></script>
</head>
<body>


<table class="layui-hide" id="test" lay-filter="test"></table>


<script>
layui.use('table', function(){
  var table = layui.table;

  table.render({
    elem: '#test',
    url:'/json/data.json'
    toolbar: true,
    title: '用户数据表',
    totalRow: true,
    cols: [[
      {field:'fat', title:'ID', width:80, fixed: 'left', unresize: true, sort: true, totalRowText: '合计行'},
      {field:'protein', title:'用户名', width:120, edit: 'text'},
      {field:'snf', title:'邮箱', width:150, edit: 'text'},
      {field:'acidity', title:'积分', width:100, sort: true, totalRow: true},
      {field:'lead', title:'性别', width:80, edit: 'text', sort: true},
      {field:'mercury', title:'登入次数', width:100, sort: true, totalRow: true},
      {field:'arsenic', title:'签名'},
      {field:'chromium', title:'城市', width:100},
      {field:'aflatoxins', title:'IP', width:120}
    ]],
    page: true,
    response: {
      statusCode: 200 //重新规定成功的状态码为 200，table 组件默认为 0
    },
    parseData: function(res){ //将原始数据解析成 table 组件所规定的数据
      return {
        "code": res.status, //解析接口状态
        "msg": res.message, //解析提示文本
        "count": res.total, //解析数据长度
        "data": res.rows.item //解析数据列表
      };
    }
  });
});
</script>

</body>
</html>